var t = getApp();

Page({
    data: {
        active: null,
        incomeListData: [],
        earningsNum: 0
    },
    onLoad: function(t) {
        this.incomeList();
    },
    incomeList: function() {
        var n = this, a = t.getNetAddresss("plugin.team-analysis.frontend.list.incomeList");
        console.log(a + ">>>>>"), t._getNetWork({
            url: a,
            success: function(t) {
                var a = t.data, o = a.data.list;
                for (var e in o) o[e].flag = !1, o[e].childrenHeight = 0;
                1 == a.result ? (console.log(a.data.list), n.setData({
                    incomeListData: o,
                    earningsNum: a.data.sum
                }), console.log(a.data), console.log(n.data.incomeListData)) : wx.showToast({
                    icon: "none",
                    title: a.msg,
                    duration: 1500
                });
            },
            fail: function(t) {
                console.log(t);
            }
        });
    },
    onListClick: function(t) {
        var n = t.currentTarget.dataset.index, a = this.data.incomeListData;
        a[n].flag = !a[n].flag, this.setData({
            incomeListData: a
        });
    },
    onTeamOrderTo: function(t) {
        var n = t.currentTarget.dataset.item;
        console.log(n), wx.navigateTo({
            url: "/packageF/balance/balance?start_time=".concat(n.start_time, "&end_time=").concat(n.end_time)
        });
    },
    onReady: function() {},
    onShow: function() {
        console.log(this.incomeListData);
    },
    onHide: function() {},
    onUnload: function() {},
    onPullDownRefresh: function() {},
    onReachBottom: function() {},
    onShareAppMessage: function() {}
});